package 字符串;

import javafx.concurrent.ScheduledService;

import java.util.Scanner;

public class 不同子串数 {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        String s = scanner.next();
        System.out.println((1+s.length())*5/2-1);
    }
}
